// 路由元信息类型
export interface RouteMeta {
  title?: string;
  requiresAuth?: boolean;
  requiresLayout?: boolean;
  isPublic?: boolean;
  icon?: string;
  [key: string]: any; // 添加字符串索引签名
  [key: symbol]: any; // 添加symbol索引签名
}

// 用户类型
export interface User {
  id: number | null;
  name: string | null;
  avatar: string | null;
  token: string | null;
}

// 系统用户类型（用于用户管理）
export interface SystemUser {
  id: number;
  name: string;
  email: string;
  role: string;
  status: string;
  createTime: string;
  lastLoginTime?: string;
  phone?: string;
  department?: string;
}

// 用户表单类型
export interface UserForm {
  id: string | number;
  name: string;
  email: string;
  role: string;
  password?: string;
  confirmPassword?: string;
  status: string;
  phone?: string;
  department?: string;
}

// 分页查询参数
export interface QueryParams {
  page: number;
  pageSize: number;
  keyword?: string;
  sortBy?: string;
  sortOrder?: 'ascending' | 'descending';
  [key: string]: any;
}

// 分页响应数据
export interface PaginationData<T> {
  list: T[];
  total: number;
  page: number;
  pageSize: number;
}

// 菜单项类型
export interface MenuItem {
  title: string;
  path: string;
  icon?: string;
  children?: MenuItem[];
} 